﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace TheatreManagementSystem
{
   public class SilverCustomer:Customer
    {
        const int threshold = 150;

        public int Threshold
        {
            get { return threshold; }
        } 

        const decimal discount = 5;
        public SilverCustomer( string firstName,string lastName, string telephoneNumer)
            : base(50, firstName,lastName ,telephoneNumer)
        {

        }
        public override decimal GetDiscount()
        {
            if (discount / 100 + attendedPerformancesCount / 1000m < 0.15m)
            {
                return discount / 100 + attendedPerformancesCount / 1000m;
            }
            else
            {
                //todo
                return 0.15m;
            }
        }

        public override bool IsThresholdReached()
        {
            if (this.attendedPerformancesCount >= threshold)
            {
                return true;
            }
            return false;
        }
    }


}
